#ifndef _IRCODE_H_
#define _IRCODE_H_

typedef struct {
	uint16_t forestClocks;
	uint16_t flatTime;
} bit_time_t;

typedef struct {
	uint16_t carrierClockHighDelayUs;	
	uint16_t carrierClockLowDelayUs;
	uint16_t isLSB;
	uint16_t sendStartBit;
	uint16_t sendStopBit;
	bit_time_t startBit;
	bit_time_t stopBit;
	bit_time_t logicalBit1;
	bit_time_t logicalBit0;
} ir_code_t;

int IRConfig(const char *buffer, int len);
void IRWrite(const char *buffer, int numberOfBits);

#endif
